import Vue from 'vue'
import Router from 'vue-router'
import Login from '@/view/login.vue'
import Donot from '@/view/changepass.vue'
import Masin from '@/view/main.vue'
import Parking from '@/view/parkingRecord.vue'
import Berth from '@/view/berth.vue'
import MM from '@/view/my.vue'
import Home from '@/view/home.vue'
import Changmy from '@/view/changemy.vue'
import Banben from '@/view/banben.vue'
import Order from '@/view/orders.vue'


Vue.use(Router)

export default new Router({
  routes: [
    {
      path: '/',
      component: Login,
    },
    {
      path: '/changepass',
      component: Donot,
    },
    {
      path: '/banben',
      component: Banben,
    },
    {
      path: '/changemy',
      component: Changmy,
    },
    {
      path: '/orders',
      component: Order,
    },
    {
      path: '/main',
      component: Masin,
      children: [
        {
          path: '/home',
          component: Home
        },
        {
          path: '/parkingRecord',
          component: Parking
        },
        {
          path: '/berth',
          component: Berth
        },
        {
          path: '/my',
          component: MM
        },
      ]
    },
  ]
})
